package com.hello.web.domain.entity;

import com.baomidou.mybatisplus.annotation.TableName;
import com.hello.common.domain.entity.BaseDO;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.persistence.Entity;
import javax.persistence.Table;
import javax.persistence.UniqueConstraint;


/**
 * 角色表
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
@Builder
@TableName("t_user")
@Entity(name = "t_user")
@Table(
        name = "t_user",
        uniqueConstraints = {
                @UniqueConstraint(columnNames = "username"),
                @UniqueConstraint(columnNames = "phone")
        }
)
@org.hibernate.annotations.Table(appliesTo = "t_user", comment = "用户表")
public class UserDO extends BaseDO {

    @ApiModelProperty(value = "用户名")
    private String username;

    @ApiModelProperty(value = "昵称")
    private String nickname;

    @ApiModelProperty(value = "手机号")
    private String phone;

    @ApiModelProperty(value = "密码")
    private String password;

    @ApiModelProperty(value = "状态 0-禁用 1-正常")
    private Integer status;


}